#include "symbols.h"
#include "lex-tools.h"
#include <stdlib.h>
#include <string.h>

int* createInteger(int intToStore){
	int* intmemory=(int*)malloc(sizeof(int));
	if (intmemory==NULL){
		return NULL;
	}
	*intmemory=intToStore;
	return intmemory;
}
char* createString(char* strToStore){
	char* strmemory=(char*)malloc((strlen(strToStore)+1)*sizeof(char));
	if (strmemory==NULL){
		return NULL;
	}
	strcpy(strmemory,strToStore);
	return strmemory;
}
bool* createBoolean(char booleanToStore){
	bool* booleanmemory=(bool*)malloc(sizeof(bool));
	if (booleanToStore=='t' || booleanToStore=='T'){
		*booleanmemory=true;
	}else{
		*booleanmemory=false;
	}
	return booleanmemory;
}

unsigned long* createUnsignedLong(unsigned long unsignedlongToStore){
	unsigned long* result=(unsigned long*)malloc(sizeof(unsigned long));

}

float* createFloat(float floatToStore){
	float* floatmemory=(float*)malloc(sizeof(float));
	if (floatmemory==NULL){
		return NULL;
	}
	*floatmemory=floatToStore;
	return floatmemory;
}

